package com.itcast.plane.util;

import lombok.Data;

@Data
public class JsonResult {
    private Boolean flag;

    private Object data;

    private String msg;

    public JsonResult() {}

    public JsonResult(Boolean flag) {
        this.flag = flag;
    }

    public JsonResult(Boolean flag, Object data) {
        this.flag = flag;
        this.data = data;
    }

    public JsonResult(Boolean flag, String msg) {
        this.flag = flag;
        this.msg = msg;
    }

    public JsonResult(String msg) {
        this.flag = false;
        this.msg = msg;
    }

    public JsonResult(Boolean flag,String msg,Object data) {
        this.flag = flag;
        this.data = data;
        this.msg = msg;
    }
}
